/*
    author:ZhengJiamin
    content:login user
 */
const mongoose = require('mongoose');

var shema = mongoose.Schema({
    name:{
        type:String,
        require:true,
    },
    email:{
        type:String,
        require:true,
    },
    password:{
        type:String,
        require:true,
    },
    role:{
        type:String,
        default:'user'
    }
});

var userModel = mongoose.model('user',shema);
exports.userModel = userModel;